<script type="text/javascript">
	function Person (name, sex) {
		this.name = name;
		this.sex = sex;
	}

	var person = new Person("lao", "male");
	var obj = {};
	Person.call(obj, "li", "female");//this是call的第一个参数，通过call的方法来让Person封装obj,通过Person构造的环节来制造obj的属性；借别人的方法来实现自己的功能
</script>

<script type="text/javascript">
	function Person (name, age) {
		this.name = name;
		this.age = age;
	}

	function Student (name, age, sex, car) {
		Person.call(this, name, age, sex, car )
		this.sex = sex;
		this.car = car;
	}

	var student = new Student();
</script>

call和apply
改变this指向，传参列表不同

<script type="text/javascript">
	function Wheel (wheelsize, style) {
		this.wheelsize = wheelsize;
		this.style = style;
	}

	function Sit (c, sitColor) {
		this.c = c;
		this.sitColor = sitColor;
	}

	function Model (height, width, len) {
		this.height = height;
		this.width = width;
		this.len = len;
	}

	function Car (wheelsize, style, c, sitColor, height, width, len) {
		Wheel.apply(this, [wheelsize, style]);
		Sit.apply(this, [c, sitColor]);
		Model.apply(this, [height, width, len]);
	}

	var car = new Car (1, 'good', 'comf', "red", 2, 3, 4);
</script>